package com.zk.spring;

import org.springframework.beans.factory.FactoryBean;

/**
 * @author ZK
 * @Description
 * @time 2021/4/25 10:47
 * @note
 */
public class FacBean implements FactoryBean<Book> {
    @Override
    public Book getObject() throws Exception {
        Book book = new Book();
        book.setBookName("java");
        book.setAuthor("ksf");
        return book;
    }

    @Override
    public Class<?> getObjectType() {
        return Book.class;
    }
}
